const express = require('express')
const app = express()
const bodyParser = require('body-parser')   // post请求时需要body-parser
const dbConfig = require('./db.config')
const app1 = require('./api/api1')
const app2 = require('./api/api2')

app.use(bodyParser.urlencoded({ extended: false }))
app.use(bodyParser.json())

app.use(app1)
app.use(app2)

app.listen(3000, () => {
  console.log('[SUCCESS] App is start successfully')
})
